import 'package:flutter/material.dart';

class BleFuncModel {
  String _name = "name";
  String _desc = "desc";
  VoidCallback? _onPressed;

  String get name => _name;

  String get desc => _desc;

  VoidCallback? get onPressed => _onPressed;

  BleFuncModel({String name = "name", String desc = "desc", VoidCallback? onPressed}) {
    _name = name;
    _desc = desc;
    _onPressed = onPressed;
  }

  BleFuncModel.fromJson(dynamic json) {
    _name = json["name"];
    _desc = json["desc"];
  }

  Map<String, dynamic> toJson() {
    var map = <String, dynamic>{};
    map["name"] = _name;
    map["desc"] = _desc;
    return map;
  }
}
